3.3.4 \(\int \sin ^2(a+b x) \sin ^3(c+d x) \, dx\) [204]

3.3.4.1 Optimal result
3.3.4.2 Mathematica [A] (verified)
3.3.4.3 Rubi [A] (verified)
3.3.4.4 Maple [A] (verified)
3.3.4.5 Fricas [A] (verification not implemented)
3.3.4.6 Sympy [B] (verification not implemented)
3.3.4.7 Maxima [B] (verification not implemented)
3.3.4.8 Giac [A] (verification not implemented)
3.3.4.9 Mupad [B] (verification not implemented)

3.3.4.1 Optimal result

Integrand size = 17, antiderivative size = 144 \[ \int \sin ^2(a+b x) \sin ^3(c+d x) \, dx=\frac {\cos (2 a-3 c+(2 b-3 d) x)}{16 (2 b-3 d)}-\frac {3 \cos (2 a-c+(2 b-d) x)}{16 (2 b-d)}-\frac {3 \cos (c+d x)}{8 d}+\frac {\cos (3 c+3 d x)}{24 d}+\frac {3 \cos (2 a+c+(2 b+d) x)}{16 (2 b+d)}-\frac {\cos (2 a+3 c+(2 b+3 d) x)}{16 (2 b+3 d)} \]

output
1/16*cos(2*a-3*c+(2*b-3*d)*x)/(2*b-3*d)-3/16*cos(2*a-c+(2*b-d)*x)/(2*b-d)- 
3/8*cos(d*x+c)/d+1/24*cos(3*d*x+3*c)/d+3/16*cos(2*a+c+(2*b+d)*x)/(2*b+d)-1 
/16*cos(2*a+3*c+(2*b+3*d)*x)/(2*b+3*d)
 
3.3.4.2 Mathematica [A] (verified)

Time = 1.68 (sec) , antiderivative size = 158, normalized size of antiderivative = 1.10 \[ \int \sin ^2(a+b x) \sin ^3(c+d x) \, dx=\frac {1}{48} \left (-\frac {18 \cos (c) \cos (d x)}{d}+\frac {2 \cos (3 c) \cos (3 d x)}{d}+\frac {3 \cos (2 a-3 c+2 b x-3 d x)}{2 b-3 d}-\frac {9 \cos (2 a-c+2 b x-d x)}{2 b-d}+\frac {9 \cos (2 a+c+2 b x+d x)}{2 b+d}-\frac {3 \cos (2 a+3 c+2 b x+3 d x)}{2 b+3 d}+\frac {18 \sin (c) \sin (d x)}{d}-\frac {2 \sin (3 c) \sin (3 d x)}{d}\right ) \]

input
Integrate[Sin[a + b*x]^2*Sin[c + d*x]^3,x]
 
output
((-18*Cos[c]*Cos[d*x])/d + (2*Cos[3*c]*Cos[3*d*x])/d + (3*Cos[2*a - 3*c + 
2*b*x - 3*d*x])/(2*b - 3*d) - (9*Cos[2*a - c + 2*b*x - d*x])/(2*b - d) + ( 
9*Cos[2*a + c + 2*b*x + d*x])/(2*b + d) - (3*Cos[2*a + 3*c + 2*b*x + 3*d*x 
])/(2*b + 3*d) + (18*Sin[c]*Sin[d*x])/d - (2*Sin[3*c]*Sin[3*d*x])/d)/48
 
3.3.4.3 Rubi [A] (verified)

Time = 0.31 (sec) , antiderivative size = 144, normalized size of antiderivative = 1.00, number of steps used = 2, number of rules used = 2, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.118, Rules used = {5080, 2009}

Below are the steps used by Rubi to obtain the solution. The rule number used for the transformation is given above next to the arrow. The rules definitions used are listed below.

\(\displaystyle \int \sin ^2(a+b x) \sin ^3(c+d x) \, dx\)

\(\Big \downarrow \) 5080

\(\displaystyle \int \left (-\frac {1}{16} \sin (2 a+x (2 b-3 d)-3 c)+\frac {3}{16} \sin (2 a+x (2 b-d)-c)-\frac {3}{16} \sin (2 a+x (2 b+d)+c)+\frac {1}{16} \sin (2 a+x (2 b+3 d)+3 c)+\frac {3}{8} \sin (c+d x)-\frac {1}{8} \sin (3 c+3 d x)\right )dx\)

\(\Big \downarrow \) 2009

\(\displaystyle \frac {\cos (2 a+x (2 b-3 d)-3 c)}{16 (2 b-3 d)}-\frac {3 \cos (2 a+x (2 b-d)-c)}{16 (2 b-d)}+\frac {3 \cos (2 a+x (2 b+d)+c)}{16 (2 b+d)}-\frac {\cos (2 a+x (2 b+3 d)+3 c)}{16 (2 b+3 d)}-\frac {3 \cos (c+d x)}{8 d}+\frac {\cos (3 c+3 d x)}{24 d}\)

input
Int[Sin[a + b*x]^2*Sin[c + d*x]^3,x]
 
output
Cos[2*a - 3*c + (2*b - 3*d)*x]/(16*(2*b - 3*d)) - (3*Cos[2*a - c + (2*b - 
d)*x])/(16*(2*b - d)) - (3*Cos[c + d*x])/(8*d) + Cos[3*c + 3*d*x]/(24*d) + 
 (3*Cos[2*a + c + (2*b + d)*x])/(16*(2*b + d)) - Cos[2*a + 3*c + (2*b + 3* 
d)*x]/(16*(2*b + 3*d))
 

3.3.4.3.1 Defintions of rubi rules used

rule 2009
Int[u_, x_Symbol] :> Simp[IntSum[u, x], x] /; SumQ[u]
 

rule 5080
Int[Sin[v_]^(p_.)*Sin[w_]^(q_.), x_Symbol] :> Int[ExpandTrigReduce[Sin[v]^p 
*Sin[w]^q, x], x] /; ((PolynomialQ[v, x] && PolynomialQ[w, x]) || (Binomial 
Q[{v, w}, x] && IndependentQ[Cancel[v/w], x])) && IGtQ[p, 0] && IGtQ[q, 0]
 
3.3.4.4 Maple [A] (verified)

Time = 1.63 (sec) , antiderivative size = 133, normalized size of antiderivative = 0.92

method result size
default \(\frac {\cos \left (2 a -3 c +\left (2 b -3 d \right ) x \right )}{32 b -48 d}-\frac {3 \cos \left (2 a -c +\left (2 b -d \right ) x \right )}{16 \left (2 b -d \right )}-\frac {3 \cos \left (d x +c \right )}{8 d}+\frac {\cos \left (3 d x +3 c \right )}{24 d}+\frac {3 \cos \left (2 a +c +\left (2 b +d \right ) x \right )}{16 \left (2 b +d \right )}-\frac {\cos \left (2 a +3 c +\left (2 b +3 d \right ) x \right )}{16 \left (2 b +3 d \right )}\) \(133\)
parallelrisch \(\frac {\left (24 b^{3} d +36 b^{2} d^{2}-6 b \,d^{3}-9 d^{4}\right ) \cos \left (2 a -3 c +\left (2 b -3 d \right ) x \right )+\left (-72 b^{3} d -36 b^{2} d^{2}+162 b \,d^{3}+81 d^{4}\right ) \cos \left (2 a -c +\left (2 b -d \right ) x \right )+\left (-24 b^{3} d +36 b^{2} d^{2}+6 b \,d^{3}-9 d^{4}\right ) \cos \left (2 a +3 c +\left (2 b +3 d \right ) x \right )+\left (72 b^{3} d -36 b^{2} d^{2}-162 b \,d^{3}+81 d^{4}\right ) \cos \left (2 a +c +\left (2 b +d \right ) x \right )+\left (32 b^{4}-80 b^{2} d^{2}+18 d^{4}\right ) \cos \left (3 d x +3 c \right )+\left (-288 b^{4}+720 b^{2} d^{2}-162 d^{4}\right ) \cos \left (d x +c \right )-256 b^{4}+640 b^{2} d^{2}}{768 b^{4} d -1920 b^{2} d^{3}+432 d^{5}}\) \(265\)
risch \(-\frac {3 \cos \left (d x +c \right ) b^{2}}{2 \left (2 b +d \right ) \left (2 b -d \right ) d}+\frac {3 d \cos \left (d x +c \right )}{8 \left (2 b +d \right ) \left (2 b -d \right )}+\frac {\cos \left (2 x b -3 d x +2 a -3 c \right ) b}{8 \left (2 b +3 d \right ) \left (2 b -3 d \right )}+\frac {3 d \cos \left (2 x b -3 d x +2 a -3 c \right )}{16 \left (2 b +3 d \right ) \left (2 b -3 d \right )}-\frac {3 \cos \left (2 x b -d x +2 a -c \right ) b}{8 \left (2 b +d \right ) \left (2 b -d \right )}-\frac {3 d \cos \left (2 x b -d x +2 a -c \right )}{16 \left (2 b +d \right ) \left (2 b -d \right )}+\frac {3 \cos \left (2 x b +d x +2 a +c \right ) b}{8 \left (2 b +d \right ) \left (2 b -d \right )}-\frac {3 d \cos \left (2 x b +d x +2 a +c \right )}{16 \left (2 b +d \right ) \left (2 b -d \right )}-\frac {\cos \left (2 x b +3 d x +2 a +3 c \right ) b}{8 \left (2 b +3 d \right ) \left (2 b -3 d \right )}+\frac {3 d \cos \left (2 x b +3 d x +2 a +3 c \right )}{16 \left (2 b +3 d \right ) \left (2 b -3 d \right )}+\frac {\cos \left (3 d x +3 c \right ) b^{2}}{6 \left (2 b +3 d \right ) d \left (2 b -3 d \right )}-\frac {3 d \cos \left (3 d x +3 c \right )}{8 \left (2 b +3 d \right ) \left (2 b -3 d \right )}\) \(404\)

input
int(sin(b*x+a)^2*sin(d*x+c)^3,x,method=_RETURNVERBOSE)
 
output
1/16*cos(2*a-3*c+(2*b-3*d)*x)/(2*b-3*d)-3/16*cos(2*a-c+(2*b-d)*x)/(2*b-d)- 
3/8*cos(d*x+c)/d+1/24*cos(3*d*x+3*c)/d+3/16*cos(2*a+c+(2*b+d)*x)/(2*b+d)-1 
/16*cos(2*a+3*c+(2*b+3*d)*x)/(2*b+3*d)
 
3.3.4.5 Fricas [A] (verification not implemented)

Time = 0.25 (sec) , antiderivative size = 192, normalized size of antiderivative = 1.33 \[ \int \sin ^2(a+b x) \sin ^3(c+d x) \, dx=\frac {{\left (8 \, b^{4} - 38 \, b^{2} d^{2} + 9 \, d^{4} + 9 \, {\left (4 \, b^{2} d^{2} - d^{4}\right )} \cos \left (b x + a\right )^{2}\right )} \cos \left (d x + c\right )^{3} + 6 \, {\left ({\left (4 \, b^{3} d - b d^{3}\right )} \cos \left (b x + a\right ) \cos \left (d x + c\right )^{2} - {\left (4 \, b^{3} d - 7 \, b d^{3}\right )} \cos \left (b x + a\right )\right )} \sin \left (b x + a\right ) \sin \left (d x + c\right ) - 3 \, {\left (8 \, b^{4} - 26 \, b^{2} d^{2} + 9 \, d^{4} + 3 \, {\left (4 \, b^{2} d^{2} - 3 \, d^{4}\right )} \cos \left (b x + a\right )^{2}\right )} \cos \left (d x + c\right )}{3 \, {\left (16 \, b^{4} d - 40 \, b^{2} d^{3} + 9 \, d^{5}\right )}} \]

input
integrate(sin(b*x+a)^2*sin(d*x+c)^3,x, algorithm="fricas")
 
output
1/3*((8*b^4 - 38*b^2*d^2 + 9*d^4 + 9*(4*b^2*d^2 - d^4)*cos(b*x + a)^2)*cos 
(d*x + c)^3 + 6*((4*b^3*d - b*d^3)*cos(b*x + a)*cos(d*x + c)^2 - (4*b^3*d 
- 7*b*d^3)*cos(b*x + a))*sin(b*x + a)*sin(d*x + c) - 3*(8*b^4 - 26*b^2*d^2 
 + 9*d^4 + 3*(4*b^2*d^2 - 3*d^4)*cos(b*x + a)^2)*cos(d*x + c))/(16*b^4*d - 
 40*b^2*d^3 + 9*d^5)
 
3.3.4.6 Sympy [B] (verification not implemented)

Leaf count of result is larger than twice the leaf count of optimal. 2003 vs. \(2 (116) = 232\).

Time = 5.43 (sec) , antiderivative size = 2003, normalized size of antiderivative = 13.91 \[ \int \sin ^2(a+b x) \sin ^3(c+d x) \, dx=\text {Too large to display} \]

input
integrate(sin(b*x+a)**2*sin(d*x+c)**3,x)
 
output
Piecewise((x*sin(a)**2*sin(c)**3, Eq(b, 0) & Eq(d, 0)), (x*sin(a - 3*d*x/2 
)**2*sin(c + d*x)**3/16 - 3*x*sin(a - 3*d*x/2)**2*sin(c + d*x)*cos(c + d*x 
)**2/16 - 3*x*sin(a - 3*d*x/2)*sin(c + d*x)**2*cos(a - 3*d*x/2)*cos(c + d* 
x)/8 + x*sin(a - 3*d*x/2)*cos(a - 3*d*x/2)*cos(c + d*x)**3/8 - x*sin(c + d 
*x)**3*cos(a - 3*d*x/2)**2/16 + 3*x*sin(c + d*x)*cos(a - 3*d*x/2)**2*cos(c 
 + d*x)**2/16 - sin(a - 3*d*x/2)**2*sin(c + d*x)**2*cos(c + d*x)/d - 5*sin 
(a - 3*d*x/2)**2*cos(c + d*x)**3/(48*d) - sin(a - 3*d*x/2)*sin(c + d*x)**3 
*cos(a - 3*d*x/2)/(24*d) + 5*sin(a - 3*d*x/2)*sin(c + d*x)*cos(a - 3*d*x/2 
)*cos(c + d*x)**2/(4*d) - 9*cos(a - 3*d*x/2)**2*cos(c + d*x)**3/(16*d), Eq 
(b, -3*d/2)), (3*x*sin(a - d*x/2)**2*sin(c + d*x)**3/16 + 3*x*sin(a - d*x/ 
2)**2*sin(c + d*x)*cos(c + d*x)**2/16 - 3*x*sin(a - d*x/2)*sin(c + d*x)**2 
*cos(a - d*x/2)*cos(c + d*x)/8 - 3*x*sin(a - d*x/2)*cos(a - d*x/2)*cos(c + 
 d*x)**3/8 - 3*x*sin(c + d*x)**3*cos(a - d*x/2)**2/16 - 3*x*sin(c + d*x)*c 
os(a - d*x/2)**2*cos(c + d*x)**2/16 + 17*sin(a - d*x/2)**2*cos(c + d*x)**3 
/(48*d) + 13*sin(a - d*x/2)*sin(c + d*x)**3*cos(a - d*x/2)/(8*d) + 7*sin(a 
 - d*x/2)*sin(c + d*x)*cos(a - d*x/2)*cos(c + d*x)**2/(4*d) - sin(c + d*x) 
**2*cos(a - d*x/2)**2*cos(c + d*x)/d - 49*cos(a - d*x/2)**2*cos(c + d*x)** 
3/(48*d), Eq(b, -d/2)), (3*x*sin(a + d*x/2)**2*sin(c + d*x)**3/16 + 3*x*si 
n(a + d*x/2)**2*sin(c + d*x)*cos(c + d*x)**2/16 + 3*x*sin(a + d*x/2)*sin(c 
 + d*x)**2*cos(a + d*x/2)*cos(c + d*x)/8 + 3*x*sin(a + d*x/2)*cos(a + d...
 
3.3.4.7 Maxima [B] (verification not implemented)

Leaf count of result is larger than twice the leaf count of optimal. 1362 vs. \(2 (132) = 264\).

Time = 0.30 (sec) , antiderivative size = 1362, normalized size of antiderivative = 9.46 \[ \int \sin ^2(a+b x) \sin ^3(c+d x) \, dx=\text {Too large to display} \]

input
integrate(sin(b*x+a)^2*sin(d*x+c)^3,x, algorithm="maxima")
 
output
-1/96*(3*(8*b^3*d*cos(3*c) - 12*b^2*d^2*cos(3*c) - 2*b*d^3*cos(3*c) + 3*d^ 
4*cos(3*c))*cos((2*b + 3*d)*x + 2*a + 6*c) + 3*(8*b^3*d*cos(3*c) - 12*b^2* 
d^2*cos(3*c) - 2*b*d^3*cos(3*c) + 3*d^4*cos(3*c))*cos((2*b + 3*d)*x + 2*a) 
 - 9*(8*b^3*d*cos(3*c) - 4*b^2*d^2*cos(3*c) - 18*b*d^3*cos(3*c) + 9*d^4*co 
s(3*c))*cos((2*b + d)*x + 2*a + 4*c) - 9*(8*b^3*d*cos(3*c) - 4*b^2*d^2*cos 
(3*c) - 18*b*d^3*cos(3*c) + 9*d^4*cos(3*c))*cos((2*b + d)*x + 2*a - 2*c) + 
 9*(8*b^3*d*cos(3*c) + 4*b^2*d^2*cos(3*c) - 18*b*d^3*cos(3*c) - 9*d^4*cos( 
3*c))*cos(-(2*b - d)*x - 2*a + 4*c) + 9*(8*b^3*d*cos(3*c) + 4*b^2*d^2*cos( 
3*c) - 18*b*d^3*cos(3*c) - 9*d^4*cos(3*c))*cos(-(2*b - d)*x - 2*a - 2*c) - 
 3*(8*b^3*d*cos(3*c) + 12*b^2*d^2*cos(3*c) - 2*b*d^3*cos(3*c) - 3*d^4*cos( 
3*c))*cos(-(2*b - 3*d)*x - 2*a + 6*c) - 3*(8*b^3*d*cos(3*c) + 12*b^2*d^2*c 
os(3*c) - 2*b*d^3*cos(3*c) - 3*d^4*cos(3*c))*cos(-(2*b - 3*d)*x - 2*a) - 2 
*(16*b^4*cos(3*c) - 40*b^2*d^2*cos(3*c) + 9*d^4*cos(3*c))*cos(3*d*x) - 2*( 
16*b^4*cos(3*c) - 40*b^2*d^2*cos(3*c) + 9*d^4*cos(3*c))*cos(3*d*x + 6*c) + 
 18*(16*b^4*cos(3*c) - 40*b^2*d^2*cos(3*c) + 9*d^4*cos(3*c))*cos(d*x + 4*c 
) + 18*(16*b^4*cos(3*c) - 40*b^2*d^2*cos(3*c) + 9*d^4*cos(3*c))*cos(d*x - 
2*c) + 3*(8*b^3*d*sin(3*c) - 12*b^2*d^2*sin(3*c) - 2*b*d^3*sin(3*c) + 3*d^ 
4*sin(3*c))*sin((2*b + 3*d)*x + 2*a + 6*c) - 3*(8*b^3*d*sin(3*c) - 12*b^2* 
d^2*sin(3*c) - 2*b*d^3*sin(3*c) + 3*d^4*sin(3*c))*sin((2*b + 3*d)*x + 2*a) 
 - 9*(8*b^3*d*sin(3*c) - 4*b^2*d^2*sin(3*c) - 18*b*d^3*sin(3*c) + 9*d^4...
 
3.3.4.8 Giac [A] (verification not implemented)

Time = 0.29 (sec) , antiderivative size = 129, normalized size of antiderivative = 0.90 \[ \int \sin ^2(a+b x) \sin ^3(c+d x) \, dx=-\frac {\cos \left (2 \, b x + 3 \, d x + 2 \, a + 3 \, c\right )}{16 \, {\left (2 \, b + 3 \, d\right )}} + \frac {3 \, \cos \left (2 \, b x + d x + 2 \, a + c\right )}{16 \, {\left (2 \, b + d\right )}} - \frac {3 \, \cos \left (2 \, b x - d x + 2 \, a - c\right )}{16 \, {\left (2 \, b - d\right )}} + \frac {\cos \left (2 \, b x - 3 \, d x + 2 \, a - 3 \, c\right )}{16 \, {\left (2 \, b - 3 \, d\right )}} + \frac {\cos \left (3 \, d x + 3 \, c\right )}{24 \, d} - \frac {3 \, \cos \left (d x + c\right )}{8 \, d} \]

input
integrate(sin(b*x+a)^2*sin(d*x+c)^3,x, algorithm="giac")
 
output
-1/16*cos(2*b*x + 3*d*x + 2*a + 3*c)/(2*b + 3*d) + 3/16*cos(2*b*x + d*x + 
2*a + c)/(2*b + d) - 3/16*cos(2*b*x - d*x + 2*a - c)/(2*b - d) + 1/16*cos( 
2*b*x - 3*d*x + 2*a - 3*c)/(2*b - 3*d) + 1/24*cos(3*d*x + 3*c)/d - 3/8*cos 
(d*x + c)/d
 
3.3.4.9 Mupad [B] (verification not implemented)

Time = 22.05 (sec) , antiderivative size = 469, normalized size of antiderivative = 3.26 \[ \int \sin ^2(a+b x) \sin ^3(c+d x) \, dx={\mathrm {e}}^{a\,2{}\mathrm {i}-c\,3{}\mathrm {i}+b\,x\,2{}\mathrm {i}-d\,x\,3{}\mathrm {i}}\,\left (\frac {3\,d\,\left (2\,b+3\,d\right )}{384\,b^2\,d-864\,d^3}+\frac {{\mathrm {e}}^{-a\,2{}\mathrm {i}-b\,x\,2{}\mathrm {i}}\,\left (8\,b^2-18\,d^2\right )}{384\,b^2\,d-864\,d^3}-\frac {3\,d\,{\mathrm {e}}^{-a\,4{}\mathrm {i}-b\,x\,4{}\mathrm {i}}\,\left (2\,b-3\,d\right )}{384\,b^2\,d-864\,d^3}\right )+{\mathrm {e}}^{a\,2{}\mathrm {i}+c\,3{}\mathrm {i}+b\,x\,2{}\mathrm {i}+d\,x\,3{}\mathrm {i}}\,\left (-\frac {3\,d\,\left (2\,b-3\,d\right )}{384\,b^2\,d-864\,d^3}+\frac {{\mathrm {e}}^{-a\,2{}\mathrm {i}-b\,x\,2{}\mathrm {i}}\,\left (8\,b^2-18\,d^2\right )}{384\,b^2\,d-864\,d^3}+\frac {3\,d\,{\mathrm {e}}^{-a\,4{}\mathrm {i}-b\,x\,4{}\mathrm {i}}\,\left (2\,b+3\,d\right )}{384\,b^2\,d-864\,d^3}\right )-{\mathrm {e}}^{a\,2{}\mathrm {i}-c\,1{}\mathrm {i}+b\,x\,2{}\mathrm {i}-d\,x\,1{}\mathrm {i}}\,\left (\frac {3\,\left (2\,b+d\right )}{32\,\left (4\,b^2-d^2\right )}-\frac {3\,{\mathrm {e}}^{-a\,4{}\mathrm {i}-b\,x\,4{}\mathrm {i}}\,\left (2\,b-d\right )}{32\,\left (4\,b^2-d^2\right )}+\frac {{\mathrm {e}}^{-a\,2{}\mathrm {i}-b\,x\,2{}\mathrm {i}}\,\left (24\,b^2-6\,d^2\right )}{32\,d\,\left (4\,b^2-d^2\right )}\right )-{\mathrm {e}}^{a\,2{}\mathrm {i}+c\,1{}\mathrm {i}+b\,x\,2{}\mathrm {i}+d\,x\,1{}\mathrm {i}}\,\left (-\frac {3\,\left (2\,b-d\right )}{32\,\left (4\,b^2-d^2\right )}+\frac {3\,{\mathrm {e}}^{-a\,4{}\mathrm {i}-b\,x\,4{}\mathrm {i}}\,\left (2\,b+d\right )}{32\,\left (4\,b^2-d^2\right )}+\frac {{\mathrm {e}}^{-a\,2{}\mathrm {i}-b\,x\,2{}\mathrm {i}}\,\left (24\,b^2-6\,d^2\right )}{32\,d\,\left (4\,b^2-d^2\right )}\right ) \]

input
int(sin(a + b*x)^2*sin(c + d*x)^3,x)
 
output
exp(a*2i - c*3i + b*x*2i - d*x*3i)*((3*d*(2*b + 3*d))/(384*b^2*d - 864*d^3 
) + (exp(- a*2i - b*x*2i)*(8*b^2 - 18*d^2))/(384*b^2*d - 864*d^3) - (3*d*e 
xp(- a*4i - b*x*4i)*(2*b - 3*d))/(384*b^2*d - 864*d^3)) + exp(a*2i + c*3i 
+ b*x*2i + d*x*3i)*((exp(- a*2i - b*x*2i)*(8*b^2 - 18*d^2))/(384*b^2*d - 8 
64*d^3) - (3*d*(2*b - 3*d))/(384*b^2*d - 864*d^3) + (3*d*exp(- a*4i - b*x* 
4i)*(2*b + 3*d))/(384*b^2*d - 864*d^3)) - exp(a*2i - c*1i + b*x*2i - d*x*1 
i)*((3*(2*b + d))/(32*(4*b^2 - d^2)) - (3*exp(- a*4i - b*x*4i)*(2*b - d))/ 
(32*(4*b^2 - d^2)) + (exp(- a*2i - b*x*2i)*(24*b^2 - 6*d^2))/(32*d*(4*b^2 
- d^2))) - exp(a*2i + c*1i + b*x*2i + d*x*1i)*((3*exp(- a*4i - b*x*4i)*(2* 
b + d))/(32*(4*b^2 - d^2)) - (3*(2*b - d))/(32*(4*b^2 - d^2)) + (exp(- a*2 
i - b*x*2i)*(24*b^2 - 6*d^2))/(32*d*(4*b^2 - d^2)))